package com.olddriver.crm.util;

import lombok.AllArgsConstructor;
import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;

@Getter
@Setter
@AllArgsConstructor
@NoArgsConstructor
public class JsonResult {
    private Boolean success ;
    private String msg;

    public static JsonResult success()
    {
        return new JsonResult(true, "操作成功!");
    }

    public static JsonResult diySuccess(String msg)
    {
        return new JsonResult(true, msg);
    }

    public static JsonResult faliure() {

        return new JsonResult(false, "操作失败!");
    }

    public static JsonResult diyFaliure(String msg)
    {
        return new JsonResult(false, msg);
    }
}
